package com.sangcomz.fishbun.ui.picker;

import com.sangcomz.fishbun.adapter.image.ImageAdapter;
import com.sangcomz.fishbun.ui.picker.model.PickerListItem;
import com.sangcomz.fishbun.ui.picker.model.PickerMenuViewData;
import com.sangcomz.fishbun.ui.picker.model.PickerRepository;
import com.sangcomz.fishbun.ui.picker.model.PickerViewData;
import ohos.utils.net.Uri;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

public interface PickerContract {

    interface View {
        void showImageList(List<PickerListItem> imageList,
                           ImageAdapter adapter,
                           Boolean hasCameraInPickerPage);

        void takePicture(String saveDir);

        void setToolbarTitle(PickerViewData pickerViewData,
                             int selectedCount,
                             String albumName);

        void initToolBar(PickerViewData pickerViewData);

        void initRecyclerView(PickerViewData pickerViewData);

        void showLimitReachedMessage(String messageLimitReached);

        void showMinimumImageMessage(int currentSelectedCount);

        void showNothingSelectedMessage(String messageNotingSelected);

        void onCheckStateChange(int position, PickerListItem.Image image);

        void onCheckStateChange(PickerRepository pickerRepository);

        void showDetailView(int position);

        void finishActivity();

        void finishActivityWithResult(List<Uri> selectedImages);

        void takeANewPictureWithFinish(int position, List<Uri> addedImageList);

        void addImage(PickerListItem.Image pickerListImage);

        void onSuccessTakePicture();
    }

    interface Presenter {

        interface PickerMenuViewDataCallback {
            void callback(PickerMenuViewData pickerMenuViewData);
        }

        void takePicture();

        List<Uri> getAddedImagePathList();

        void addAddedPath(Uri addedImagePath);

        void addAllAddedPath(List<Uri> addedImagePathList);

        void release();

        void successTakePicture(Uri addedImagePath);

        void getPickerListItem();

        void transImageFinish();

        void getDesignViewData();

        void onClickThumbCount(int position);

        void onClickImage(int position);

        void onDetailImageActivityResult();

        void getPickerMenuViewData(PickerMenuViewDataCallback callback);

        void onClickMenuDone();

        void onClickMenuAllDone();

        void onSuccessTakePicture();
    }
}
